-- GENERATED SPELL FOR [Infinite Adversary] --


function spell0_27742(pUnit, Event) --@Void Shield,Self--
pUnit:FullCastSpellOnTarget(52634,pUnit)
pUnit:RegisterEvent('Sorts_27742', 8252, 1)
end

function spell1_27742(pUnit, Event) --@Void Shield,Self--
pUnit:FullCastSpellOnTarget(58813,pUnit)
pUnit:RegisterEvent('Sorts_27742', 8339, 1)
end

function spell2_27742(pUnit, Event) --@Void Strike,n/a--
pUnit:FullCastSpellOnTarget(52633,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_27742', 525, 1)
end

function Sorts_27742(pUnit, Event)
local choix_sorts_27742 = math.random(0, 2)
if choix_sorts_27742 == 0 then
pUnit:RegisterEvent('spell0_27742', 1, 1)
end
if choix_sorts_27742 == 1 then
pUnit:RegisterEvent('spell1_27742', 1, 1)
end
if choix_sorts_27742 == 2 then
pUnit:RegisterEvent('spell2_27742', 1, 1)
end
end

function mob27742_Action(pUnit, Event)
pUnit:RegisterEvent('Sorts_27742', math.random(1500, 3000), 1)
end

function mob27742_Leave(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob27742_Kill(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob27742_Die(pUnit, Event)
pUnit:RemoveEvents();
end

RegisterUnitEvent(27742, 1, 'mob27742_Action')
RegisterUnitEvent(27742, 2, 'mob27742_Leave')
RegisterUnitEvent(27742, 3, 'mob27742_Kill')
RegisterUnitEvent(27742, 4, 'mob27742_Die')
